package com.ym.medical.enums;

import com.alibaba.fastjson.JSONObject;
import com.fasterxml.jackson.databind.util.StdConverter;
import com.ym.common.annotations.EnumDescription;
import com.ym.common.constant.DictEnum;

/**
 * 举报记录-举报类型
 */
@EnumDescription("举报记录-举报类型")
public enum UserBadRecordUpTypeEnum implements DictEnum {

	//--------------------start-----------------

	/**
	 * 法律禁止
	 */
	PROHIBITED_BY_LAW_FROM("01","法律禁止"),
	/**
	 * 涉黄涉暴
	 */
	SUGGESTIVE_INVOLVED_VIOLENCE("02","涉黄涉暴"),
	/**
	 * 个人骚扰
	 */
	PERSONAL_HARASSMENT("03","个人骚扰"),
	/**
	 * 非医疗
	 */
	NON_MEDICAL("04","非医疗"),

	//--------------------end-------------------
	;

	private String key;

	private String value;

	UserBadRecordUpTypeEnum(String key, String value) {
		this.key = key;
		this.value = value;
	}

	@Override
	public String getKey() {
		return this.key;
	}

	@Override
	public String getValue() {
		return this.value;
	}


	/**
	 * 序列化使用
	 */
	public static class Covert extends StdConverter<String, JSONObject> {
		@Override
		public JSONObject convert(String value) {
			return DictEnum.valueOfJson(UserBadRecordUpTypeEnum.class, value);
		}
	}
}
